The present invention relates to a pattern recognition device and, particularly, to such device useful in recognizing minute defects on a printed circuit board, a coating of an automobile or a lens, etc., by means of a television camera.
A proposal is disclosed in Japanese Patent Application Laid-open No. 39581/1985, in which an existence of an article or defects in various portions thereof is recognized by deciding whether or not a signal level of a portion of a video signal of the article which corresponds to an area of the article to be monitored is within a predetermined range. In detail, luminance of the video signal corresponding to the monitor region of the article is compared with luminance of a video signal of a corresponding region of a standard article ( referred to as "master" hereinafter ) having a normal contour and it is decided that the monitor region contains a defect when there is a difference in luminance therebetween.
In a case where a minute defect or defects existing in a wide monitor region of a device such as a printed circuit board, an automobile coating, a lens, etc., are to be detected, it is necessary to reliably detect even a very small variation of luminance of the video signal thereof which is not included in the signal from the master Since an area of such a defect may be considerably smaller than that of the monitor region, it is difficult, practically, to derive a video signal portion corresponding to the defect from a video signal of the monitor region when there is a portion or portions, such as a curved, angled or patterned portion which may reflect illumination light considerably locally causing a wide and considerable variation of luminance to be produced regardless of defect, included in the monitor region, which may constitute a background noise large enough to make the intended video signal portion inseparable therefrom. This fact is very severe when the portion in question is a border line of the monitor region.
When the latter is the case and when the video signal of the monitor region is displaced in position relatively to that of the master or the monitor region is different in size from the master region, luminance information obtained from such displaced border region becomes considerably larger than that of the minute defect even if such positional displacement is within an acceptable range and thus it becomes impossible to distinguish the defect therefrom.
Therefore, in order to detect such a minute defect precisely, it is necessary to successively compare respective pixels of the monitor region with those of the master region one by one. In this case, the problem of the positional displacement between the monitor and the master regions becomes very severe causing this approach not to be practical.